<template>
  <div class="ps-echart-title">
    <div class="ps-echart-title-main">{{ title }}</div>
    <div class="ps-echart-title-sub" v-if="subTitle">{{ subTitle }}</div>
  </div>
</template>

<script setup>
const props = defineProps({
  title: {
    type: String,
    required: true,
    default: ''
  },
  subTitle: {
    type: String,
    default: ''
  }
})
</script>

<style scoped lang="scss">
.ps-echart-title {
  height: 40px;
  .ps-echart-title-main {
    font-weight: bold;
  }

  .ps-echart-title-sub {
    font-size: 10px;
    text-align: end;
    margin-right: 30px;
  }
}
</style>
